home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 1
/
Cream of the Crop 1.iso
/
UTILITY
/
DO1002.ARJ
/
DOIT.SCR
< prev
next >
Wrap
Text File
|
1991-12-29
|
2KB
|
47 lines
.pg wi full clr
/GOSUB DOHEADER
Executes DOS commands and programs.
»cy«{flags}»#« Optional flags that control the display
during command execution:
»ye«P»gr« = »wh«pause after execution»#«
»cy«{command}»#« The actual DOS command to be executed.
»%t«DO»#« executes another shell to
execute the command. Variables in
»cy«{command}»#« will be expanded to their
values before execution.
»%t«DoIt»#« will swap as much of the »%t«DO»#« program out of memory as it
can before executing the command. If you have »ye«EMS»#«, it will
do that, otherwise, it will create a »gr«swap file»#« on the current
directory.
.pg clr
We'll use the »cy«DOS "DIR/w"»#« command to illustrate the operation
of the »%t«DoIt»#« command. Press »bo«<enter>»#« to execute each of
the commands after you have examined them.
.pg clr
First a simple directory:
.go 1 10
|!DIR/w
/GOSUB DOHEADER
That went by too fast to get a good look at. Let's use the
"»cy«P»#«" flag to pause the display before returning to the »%t«DO»#«
script. Press »bo«<enter>»#« after viewing the directory.
.go 1 10
|!P;DIR/w
/GOSUB DoHeader
That's better!
/GOTO DOEND
:DOHEADER
.wi full clr
»cy«COMMAND NAME»gy«: »%t«DoIt»ye«
![{flags};]{command}
/CW
/RETURN
:DOEND
/ENDEXEC CLEAR